package builder

import "fmt"

type Burger struct {
	Size      int
	Cheese    bool
	Pepperoni bool
	Tomato    bool
	Lettuce   bool
}

type BurgerBuilder struct {
	burger *Burger
}

func (b *BurgerBuilder) SetSize(size int) Builder {
	b.burger.Size = size
	return b
}
func (b *BurgerBuilder) SetCheese(cheese bool) Builder {
	b.burger.Cheese = cheese
	return b
}
func (b *BurgerBuilder) SetPepperoni(pepperoni bool) Builder {
	b.burger.Pepperoni = pepperoni
	return b
}
func (b *BurgerBuilder) SetTomato(tomato bool) Builder {
	b.burger.Tomato = tomato
	return b
}
func (b *BurgerBuilder) SetLettuce(lettuce bool) Builder {
	b.burger.Lettuce = lettuce
	return b
}
func (b *BurgerBuilder) Print() {
	fmt.Printf("Burger info size: %d\n", b.burger.Size)
}

func NewBurgerBuilder() Builder {
	return &BurgerBuilder{burger: &Burger{}}
}
